package com.authsphere.logging.kafka.config;

import com.authsphere.logging.common.config.GenericGlobalConfig;
import com.authsphere.logging.common.utils.LogCollectConfigUtils;

/**
 * @program: tech4j
 * @description:
 * @author: YuKai Fan
 * @create: 2025/3/5 21:09
 **/
public class KafkaLogCollectConfig {
    private KafkaLogConfig kafkaLogConfig;

    public KafkaLogConfig getKafkaLogConfig() {
        return kafkaLogConfig;
    }

    public void setKafkaLogConfig(KafkaLogConfig kafkaLogConfig) {
        this.kafkaLogConfig = kafkaLogConfig;
        LogCollectConfigUtils.setGenericGlobalConfig(kafkaLogConfig);
    }

    public static class KafkaLogConfig extends GenericGlobalConfig {

        private String topic;

        private String namesrvAddr;

        private String producerGroup;

        private String compressAlg = "LZ4";

        private String securityProtocol;

        private String saslMechanism;

        private String userName;

        private String passWord;

        public String getTopic() {
            return topic;
        }

        public void setTopic(String topic) {
            this.topic = topic;
        }

        public String getNamesrvAddr() {
            return namesrvAddr;
        }

        public void setNamesrvAddr(String namesrvAddr) {
            this.namesrvAddr = namesrvAddr;
        }

        public String getProducerGroup() {
            return producerGroup;
        }

        public void setProducerGroup(String producerGroup) {
            this.producerGroup = producerGroup;
        }

        public String getCompressAlg() {
            return compressAlg;
        }

        public void setCompressAlg(String compressAlg) {
            this.compressAlg = compressAlg;
        }

        public String getSecurityProtocol() {
            return securityProtocol;
        }

        public void setSecurityProtocol(String securityProtocol) {
            this.securityProtocol = securityProtocol;
        }

        public String getSaslMechanism() {
            return saslMechanism;
        }

        public void setSaslMechanism(String saslMechanism) {
            this.saslMechanism = saslMechanism;
        }

        public String getUserName() {
            return userName;
        }

        public void setUserName(String userName) {
            this.userName = userName;
        }

        public String getPassWord() {
            return passWord;
        }

        public void setPassWord(String passWord) {
            this.passWord = passWord;
        }
    }
}
